﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;

namespace B.S.Meeting.Infrastructure.Interfaces
{
    public interface IBaseRepository<T> where T : class
    {
        Task<int> AddAsync(T entity);
        IQueryable<T> GetAll();
        Task<T> GetAsync(Expression<Func<T, bool>> expression);
        Task<int> UpdAsync(T entity);

        Task<int> Del(int id);

        Task<T> GetByIdAsync(int id);

        Task<int> BatchDel(List<T> list);
    }
}
